﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Skynet.WebAdministracion.Views.EvaluationMgm;
using Microsoft.Practices.Unity;
using Skynet.WebAdministracion.Views.ExamByCustomerDashboard;
namespace Skynet.WebSite.Evaluation
{
    public partial class Default : Infrastructure.Web.Views.Page, IExamByCustomerDashboardView
    {
        private ExamByCustomerDashboardPresenter _Presenter;
        [Dependency]
        public ExamByCustomerDashboardPresenter Presenter
        {
            get { return _Presenter; }
            set
            {
                _Presenter = value;
                this._Presenter.View = this;
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {            
            if (!Page.IsPostBack)
                this.Presenter.OnViewInitialized();
            this.Presenter.OnViewLoaded();  
        }

        public int ActiveExams
        {
            set { this.lblActiveExams.Text = value.ToString();  }
        }
        public int RunningExams
        {
            set { this.lblRunningExams.Text = value.ToString(); }
        }

        public int ResultExams
        {
            set { this.lblExamResults.Text = value.ToString(); }
        }        

        protected void lbActiveExams_Click(object sender, EventArgs e)
        {
            this.Presenter.ShowActiveExams();
        }

        protected void lbRunningExams_Click(object sender, EventArgs e)
        {
            this.Presenter.ShowRunningExams();
        }

        protected void lbExamResults_Click(object sender, EventArgs e)
        {
            this.Presenter.ShowExamResults();
        }

        
    }
}